﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;

/// <summary>
/// Summary description for EditDongHoKhachHangEntities
/// </summary>
namespace Data
{
    public class EditDongHoKhachHangEntities
    {
        #region khai bao thuoc tinh
        private int _OBJECTID;
        private string _IDMaDongHo;
        private string _TieuChuan;
        private int _NamSanXuat;
        private string _NhaSanXuat;
        public EditDongHoKhachHangEntities()
        {

        }

        public int OBJECTID
        {
            get { return _OBJECTID; }
            set { _OBJECTID = value; }
        }

        public string IDMaDongHo
        {
            get { return _IDMaDongHo; }
            set { _IDMaDongHo = value; }
        }

        public string TieuChuan
        {
            get { return _TieuChuan; }
            set { _TieuChuan = value; }
        }

        public int NamSanXuat
        {
            get { return _NamSanXuat; }
            set { _NamSanXuat = value; }
        }

        public string NhaSanXuat
        {
            get { return _NhaSanXuat; }
            set { _NhaSanXuat = value; }
        }

        # endregion khai bao

        #region phuong thuc
        public EditDongHoKhachHangEntities DongHoKhachHangInfo(System.Data.IDataReader dr)
        {
            //Convert.ToInt32
            Data.EditDongHoKhachHangEntities obj = new Data.EditDongHoKhachHangEntities();
            obj.OBJECTID = (dr["OBJECTID"] is DBNull) ? 0 : Convert.ToInt32(dr["OBJECTID"]);
            obj.IDMaDongHo = (dr["IDMaDongHo"] is DBNull) ? string.Empty : dr["IDMaDongHo"].ToString();
            obj.TieuChuan = (dr["TieuChuan"] is DBNull) ? string.Empty : dr["TieuChuan"].ToString();
            obj.NamSanXuat = (dr["NamSanXuat"] is DBNull) ? 0 : Convert.ToInt32(dr["NamSanXuat"]);
            obj.NhaSanXuat = (dr["NhaSanXuat"] is DBNull) ? string.Empty : dr["NhaSanXuat"].ToString();
            return obj;
        }
        #endregion phuong thuc
    }
}